// pages/home/home.js
Page({

  /**
   * 页面的初始数据
   */
  data: {
    option:[
      {
        "id":"001",
        "title":"首页"
      },
      {
        "id":"002",
        "title":"新品"
      },
      {
        "id":"003",
        "title":"全屋家具"
      },
      {
        "id":"004",
        "title":"床品"
      },
      {
        "id":"005",
        "title":"家居服"
      },
      {
        "id":"006",
        "title":"下厨"
      },
      {
        "id":"007",
        "title":"家务"
      },
      {
        "id":"008",
        "title": "生活日用"
      },
      {
        "id":"008",
        "title":"洗沐"
      },
      {
        "id":"008",
        "title":"了解LifeVC"
      }
    ],
    isChecked: "002",
    banners:[
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/044fe1fbd00a416186849894d700b2f8.jpg",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/9ec66f01521041889bb5ceac8fb6f54f.jpg",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/7f8d67c7cb32464581f621c4da3befb0.jpg",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/cf62a202f30b4dd1b9e985b625ea62c7.jpg",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/6bbfc593252e442d951fe20d09afbeee.jpg",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/b744ebb443754fa08e70bb1eed87f6f2.jpg",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/7fc77825152c4836bea032e2585a3a48.jpg ",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/99e396a4b8d54d578068cd47bfc8042d.jpg",
      "http://i1.lifevccdn.com//Upload/AppCategoryBanner/8b003901e88343e28c616a7e3be63066.jpg"
    ]
  },
  selectStyle(e) {
     this.setData({
       isChecked:e.target.dataset.index
     })
  },
  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {

  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {

  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {
    if (typeof this.getTabBar === 'function' &&  this.getTabBar()) {
      this.getTabBar().setData({
        selected: 0
      })
    }
  },
  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {

  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {

  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  }
})